//2009/08/11 14:56:37
#include <string>
#include <vector>
#include <map>
#include <queue>
#include <algorithm>

using namespace std;

class Soccer
{
public:
    int maxPoints(vector <int> wins, vector <int> ties)
    {
		int mmax = 0;
		for(int i=0; i<wins.size(); i++)
		{
			mmax = max(mmax, 3*wins[i]+ties[i]);
		}
		return mmax;
    }
};
